Camera Manager
Interface for managing camera.
Functions
addPersistentStyleCustomLayer
Link copied to clipboard
@NonNull()
Content copied to clipboard
Adds a new [style custom layer](https://docs.mapbox.com/mapbox-gl-js/style-spec/#layers).Note: This is an experimental API and is a subject to change.Whenever a new style is being parsed and currently used style has persistent layers,an engine will try to do following:- keep the persistent layer at its relative position- keep the source used by a persistent layer- keep images added through `addStyleImage` methodIn cases when a new style has the same layer, source or image resource, style's resources would beused instead and `MapLoadingError` event will be emitted.
addPersistentStyleLayer
Link copied to clipboard
@NonNull()
Content copied to clipboard
Adds a new [style layer](https://docs.mapbox.com/mapbox-gl-js/style-spec/#layers).Note: This is an experimental API and is a subject to change.Whenever a new style is being parsed and currently used style has persistent layers,an engine will try to do following:- keep the persistent layer at its relative position- keep the source used by a persistent layer- keep images added through `addStyleImage` methodIn cases when a new style has the same layer, source or image resource, style's resources would beused instead and `MapLoadingError` event will be emitted.
addStyleCustomGeometrySource
Link copied to clipboard
@NonNull()
Content copied to clipboard
addStyleCustomLayer
Link copied to clipboard
@NonNull()
Content copied to clipboard
addStyleImage
Link copied to clipboard
@NonNull()
Content copied to clipboard
addStyleLayer
Link copied to clipboard
@NonNull()
Content copied to clipboard
addStyleSource
Link copied to clipboard
cameraForCoordinateBounds
Link copied to clipboard
@NonNull()
Content copied to clipboard
cameraForCoordinates
Link copied to clipboard
@NonNull()
Content copied to clipboard
Convenience method that adjusts the provided `camera options` object for given parameters.Returns the provided `camera` options with zoom adjusted to fit `coordinates` into the `box`, so that `coordinates` on the left,top and right of the effective `camera` center at the principal point of the projection (defined by `padding`) fit into the `box`.Returns the provided `camera` options object unchanged upon an error.Note that this method may fail if the principal point of the projection is not inside the `box` orif there is no sufficient screen space, defined by principal point and the `box`, to fit the geometry.
@NonNull()
Content copied to clipboard
cameraForGeometry
Link copied to clipboard
@NonNull()
Content copied to clipboard
coordinateBoundsForCamera
Link copied to clipboard
@NonNull()
Content copied to clipboard
coordinateBoundsZoomForCamera
Link copied to clipboard
@NonNull()
Content copied to clipboard
coordinateBoundsZoomForCameraUnwrapped
Link copied to clipboard
@NonNull()
Content copied to clipboard
coordinateForPixel
Link copied to clipboard
@NonNull()
Content copied to clipboard
coordinatesForPixels
Link copied to clipboard
@NonNull()
Content copied to clipboard
dragStart
Link copied to clipboard
getBounds
Link copied to clipboard
getCameraState
Link copied to clipboard
getDragCameraOptions
Link copied to clipboard
@NonNull()
Content copied to clipboard
getFreeCameraOptions
Link copied to clipboard
getMapProjection
Link copied to clipboard
getStyleDefaultCamera
Link copied to clipboard
Returns the map style's default camera, if any, or a default camera otherwise.The map style's default camera is defined as follows:- [center](https://docs.mapbox.com/mapbox-gl-js/style-spec/#root-center)- [zoom](https://docs.mapbox.com/mapbox-gl-js/style-spec/#root-zoom)- [bearing](https://docs.mapbox.com/mapbox-gl-js/style-spec/#root-bearing)- [pitch](https://docs.mapbox.com/mapbox-gl-js/style-spec/#root-pitch)The style default camera is re-evaluated when a new style is loaded.
getStyleImage
Link copied to clipboard
getStyleJSON
Link copied to clipboard
getStyleLayerProperties
Link copied to clipboard
getStyleLayerProperty
Link copied to clipboard
@NonNull()
Content copied to clipboard
getStyleLayerPropertyDefaultValue
Link copied to clipboard
@NonNull()
Content copied to clipboard
getStyleLayers
Link copied to clipboard
getStyleLightProperty
Link copied to clipboard
@NonNull()
Content copied to clipboard
getStyleSourceProperties
Link copied to clipboard
getStyleSourceProperty
Link copied to clipboard
@NonNull()
Content copied to clipboard
getStyleSourcePropertyDefaultValue
Link copied to clipboard
@NonNull()
Content copied to clipboard
getStyleSources
Link copied to clipboard
getStyleTerrainProperty
Link copied to clipboard
@NonNull()
Content copied to clipboard
getStyleTransition
Link copied to clipboard
getStyleURI
Link copied to clipboard
invalidateStyleCustomGeometrySourceRegion
Link copied to clipboard
@NonNull()
Content copied to clipboard
invalidateStyleCustomGeometrySourceTile
Link copied to clipboard
@NonNull()
Content copied to clipboard
isStyleLayerPersistent
Link copied to clipboard
isStyleLoaded
Link copied to clipboard
Check if the style is completely loaded.Note: The style specified sprite would be marked as loaded even with sprite loading error (An error will be emitted via `MapLoadingError`).Sprite loading error is not fatal and we don't want it to block the map rendering, thus the function will still return `true` if style and sources are fully loaded.
moveStyleLayer
Link copied to clipboard
@NonNull()
Content copied to clipboard
pixelForCoordinate
Link copied to clipboard
@NonNull()
Content copied to clipboard
pixelsForCoordinates
Link copied to clipboard
@NonNull()
Content copied to clipboard
removeStyleImage
Link copied to clipboard
removeStyleLayer
Link copied to clipboard
removeStyleSource
Link copied to clipboard
setCamera
Link copied to clipboard
Changes the map view by any combination of center, zoom, bearing, and pitch, without an animated transition.The map will retain its current values for any details not passed via the camera options argument.It is not guaranteed that the provided `camera options` will be set, the map may apply constraints resulting in adifferent `camera state`.
setMapProjection
Link copied to clipboard
setStyleCustomGeometrySourceTileData
Link copied to clipboard
setStyleJSON
Link copied to clipboard
setStyleLayerProperties
Link copied to clipboard
setStyleLight
Link copied to clipboard
setStyleLightProperty
Link copied to clipboard
setStyleSourceProperties
Link copied to clipboard
setStyleSourceProperty
Link copied to clipboard
setStyleTerrain
Link copied to clipboard
setStyleTerrainProperty
Link copied to clipboard
setStyleTransition
Link copied to clipboard
open fun setStyleTransition(@NonNull() transitionOptions: TransitionOptions)
Content copied to clipboard
setStyleURI
Link copied to clipboard
styleLayerExists
Link copied to clipboard
styleSourceExists
Link copied to clipboard
subscribe
Link copied to clipboard
unsubscribe
Link copied to clipboard
updateStyleImageSourceImage
Link copied to clipboard